from app import create_app
from app.database import initialize_mongodb

app = create_app()

if __name__ == '__main__':
    # 初始化MongoDB
    initialize_mongodb()
    
    # 启动应用
    app.run(
        host='0.0.0.0',
        port=5002
    )